/*
 * Filename    : SceneManager.java
 * Projectname : CobaScene
 * Date        : Jan 1, 2013 , 9:02:56 PM 
 * 
 */

package id.pratama.soiscene;

import id.pratama.soiscene.scene.Scene_Alat_Musik;
import id.pratama.soiscene.scene.Scene_Logo;
import id.pratama.soiscene.scene.Scene_Menu;
import id.pratama.soiscene.scene.Scene_Playing;

import org.andengine.entity.scene.Scene;
import org.andengine.ui.activity.BaseGameActivity;

public class SceneManager
{
	public static final int		SCENE_LOGO		= 1;
	public static final int		SCENE_MENU		= 2;
	public static final int		SCENE_ALATMUSIK	= 3;
	public static final int		SCENE_INFOALAT	= 4;
	public static final int		SCENE_PLAYING	= 5;
	public static int			currentScene	= 0;

	private BaseGameActivity	activity;
	public static Scene			loadedScene;

	public SceneManager(BaseGameActivity pActivity)
	{
		// TODO Auto-generated constructor stub
		activity = pActivity;
	}

	public void setScene(int scene)
	{
		currentScene = scene;
		switch (scene)
		{
			case SCENE_LOGO:
				loadedScene = new Scene_Logo(activity);
				break;
			case SCENE_MENU:
				loadedScene = new Scene_Menu(activity);
				break;
			case SCENE_ALATMUSIK:
				loadedScene = new Scene_Alat_Musik(activity);
				break;
			case SCENE_PLAYING:
				loadedScene = new Scene_Playing(activity);
				break;

		}
		activity.getEngine().setScene(loadedScene);
	}
}
